package entity;

import java.io.Serializable;

public class ResultVo implements Serializable {
    private String code;//状态码
    private String msg;//描述信息
    private Object data;//返回的数据
    //alter+enter
    //空参

    public ResultVo() {
    }

    //L两参 , code,msg
    public ResultVo(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    //三参

    public ResultVo(String code, String msg, Object data) {
        this.code = code;
        this.msg = msg;
        this.data = data;
    }

    //getter/setter

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }

    //toString

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("ResultVo{");
        sb.append("code='").append(code).append('\'');
        sb.append(", msg='").append(msg).append('\'');
        sb.append(", data=").append(data);
        sb.append('}');
        return sb.toString();
    }

}
